<?php
/** $Id: default_form.php 11917 2009-05-29 19:37:05Z ian $ */
	defined( '_JEXEC' ) or die( 'Restricted access' );
	$session = JFactory::getSession();
	$app = JFactory::getApplication();
	$template = JURI::base() . 'templates/' . $app->getTemplate();
?>
<div id="header">
  <div id="w-header">
    <div class="logo"><a href="index.php">Forside</a> </div>
    <!--.logo-->
     {module login menu}    
    <!--.nav-top-1-->
    <div class="clear"></div>
    <div class="main-nav">
      {module main menu}
    </div>
    <!--.main-nav-->
    <div class="clear"></div>
  </div>
  <!--#w-header--> 
</div>
<!--#header-->

<div id="main">
  <div id="w-main">
    <div id="main-left">
	<div class="left-find"></div>
	<div class="right-find"></div>
		<div class="find">
			{module search}
		</div> 
      <!--.find-->
      <div class="clear"></div>
      <div class="infomation">
		<?php $article = JUtility::getArticle(15); ?>
        <h2><a href="#"><?php echo $article->title; ?></a></h2>
        <?php echo $article->introtext; ?>
      </div>
      <!--.infomation--> 
    </div>
    <!--#main-left-->
  <div id="main-right2">
      <div id="get-offer-page">
        <div class="order">
          <div class="title">CATERINGSVIRKSOMHED</div>
          <!--.title-->
          
           <?php 
		   	 	 $orders_catering = $this->data->getAllCatering();
				if(count($orders_catering)>0) {
		   		 foreach($orders_catering as $item) {
                  
				 $order = $this->data->getOrder($item->jobid);
				 $order_caterer = $this->data->getUserInfo($item->catererid);
				 $order_user = $this->data->getUserInfo($order->userid);
				
		   ?>
            
          <div class="order-item">
            <div class="order-item-top"></div>
            <!--.order-item-top-->
            <div class="order-item-mid">
              <div class="order-info-left">
                <h3><a href="<?php echo JRoute::_('index.php?option=com_jobs&view=cateringdetail&eventid='.$item->id);?>"><?php echo $order_caterer->name;?>'S CATERING.</a></h3>
                <p><?php echo $order->title; ?></p>
                <p><?php echo $order->description; ?></p>
              </div>
              <!--.order-info-left-->
              <div class="order-info-right">
                <ul>
                  <li>
                    <h2>KVALITET</h2>
                    <span><?php echo $item->rating_quality; ?></span> </li>
                  <li>
                    <h2>SERVICE</h2>
                    <span><?php echo $item->rating_service; ?></span> </li>
                </ul>
              </div>
              <!--.order-info-right--> 
            </div>
            <!--.order-item-mid-->
            <div class="order-item-bottom"></div>
            <!--.order-item-bottom--> 
          </div>
          <!--.order-item-->
          <?php } 
				} 
				else 
				{
					?>
                    <div class="order-item">
                        <div>
                        <?php
						 $article = JUtility::getArticle(14);
						 echo $article->introtext;
						 ?>
                        </div>
                    </div>
                    <?php
				}
			?>
          
          
        </div>
        <!--.order-->
        <?php if(count($orders_catering)>0) { ?>
        <div class="move-top"><a href="#top"><img src="templates/kokketilbud/images/move-top.png" width="23" height="21" alt=""></a></div>
        <?php } ?>
        <!--.move-top--> 
      </div>
      <!--#get-offer-page--> 
    </div>
    <!--#main-right--> 
  </div>
  <!--#w-main--> 
</div>
<!--#main-->
<div class="clear"></div>
<div id="contact">
  <div id="w-contact">
     <div class="left-con">
      <div class="left-con-top"></div>
      <!--left-con-top-->
      <div class="left-con-mid">
        <div class="contact-con">
		<?php $article = JUtility::getArticle(17); ?>
          <h2><a href="#"><?php echo $article->title; ?></a></h2>
          <?php echo $article->introtext; ?>
        </div>
        <!--.contact-con-->
        <div class="contact-con contact-con2">
			<?php $article = JUtility::getArticle(18); ?>
			<h2><a href="#"><?php echo $article->title; ?></a></h2>
			<?php echo $article->introtext; ?>
        </div>
        <!--.contact-con--> 
      </div>
      <!--left-con-mid-->
      <div class="left-con-bottom"></div>
      <!--left-con-bottom--> 
    </div>
    <!--.left-con-->
    
    <div class="address">
		<?php $article = JUtility::getArticle(16); ?>
		<h2><?php echo $article->title; ?></h2>
		<?php echo $article->introtext; ?>
    </div>
    <!--address--> 
    
    <div class="contact-form">
		{module kontakt}
    </div><!--.contact-form-->
  </div>
  <!--w-contact--> 
</div>
<!--#contact-->
<div class="clear"></div>
<div id="copyright">
	<div id="w-copyright">
		{module footer}
	</div>
</div>
<!--#copyright-->